package Translate;
import Tree.*;

public class procEntryExit {
	public procEntryExit(Level level,Exp body,boolean hasReturn){
		Stm b=null;
		if(hasReturn){
			b = new MOVE(new TEMP(level.frame.rv),body.unEx());
		}
		else{
			b=body.unNx();
		}
		
		b=level.frame.procEntryExit1(b);
		addFrag(new ProFrag(b,level.frame,b));
	}

}
